<?php

namespace app\admin\model;

use app\common\model\Group;
use app\common\model\BaseModel;
use think\model\relation\BelongsTo;
use think\model\relation\HasMany;

class GroupUser extends BaseModel
{
    protected $hidden = ['password', 'delete_time'];

    public function group(): BelongsTo
    {
        return $this->belongsTo(Group::class, 'group_id', 'id');
    }

    public function userAuth(): HasMany
    {
        return $this->hasMany(GroupUserAuth::class);
    }

}